<!-- 电子签章-审批流程弹框 -->
<template>
  <div>
    <MyTable
      id="id"
      ref="myTableRef"
      :is-selection="false"
      :table-data="tableData"
      :columns="colOption"
      :col-option-enum="dicLists"
    />
  </div>
</template>

<script>
import MyTable from '@/components/basic/myTable'
import SysConst from '@/common/const'
import { signDetailApi } from '@/api/attachManagement/electronicSign/electronicSignature'

const colOption = [
    { label: '签署类型', width: '120', prop: 'signType' },
    { label: '签署公司', width: '', prop: 'signCompany' },
    { label: '签署人', width: '120', prop: 'signName' },
    { label: '签署时间', width: '180', prop: 'dateTime' }
]
export default {
    name: 'SignStatusList',
    components: {
        MyTable
    },
    props: {
        signStatusId: {
            type: String,
            default: ''
        }
    },
    data() {
        return {
            tableData: [],
            colOption,
            dicLists: {},
            // 分页信息
            pageParam: {
                pageSize: SysConst.PAGESIZE, // 每页显示val条
                pageNum: SysConst.CURRENT_PAGE, // 当前页
                total: SysConst.TOTAL // 总数
            }
        }
    },
    created() {
        this.getSignDetail()
    },
    methods: {
        // 查询审批流程列表
        getSignDetail() {
            signDetailApi({ id: this.signStatusId }).then(res => {
                if (+res.code !== 200) {
                    return Promise.reject(res)
                }
                this.tableData = res.data
            })
        }
    }
}
</script>
